package com.iespring.bean.app.user.bo;

import lombok.Data;
import lombok.NoArgsConstructor;
import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.Pattern;

/**
 * Auth: 杨宇健
 * Time: 2023/1/2 14:58
 * Description:
 **/
@NoArgsConstructor
@Data
public class UserRegisterBo {

    /**
     * username : 21343124
     * password : @a123456
     * mobile : 19392803703
     * code : 124414
     * wxCode : 093bpR100ETIcP1NJd2008QO7m1bpR1z
     */
    @Length(min = 3, max = 8, message = "名字长度最小为3，最长为8")
    private String username;
    @Pattern(regexp = "^(?=.*[0-9])(?=.*[a-zA-Z])(.{8,20})$",
            message = "密码长度为8到20位,必须包含字母和数字，字母区分大小写")
    private String password;
    private String mobile;
    private String code;
    private String wxCode;
}
